home *** CD-ROM | disk | FTP | other *** search
/ Linux Cubed Series 4: GNU Archives / Linux Cubed Series 4 - GNU Archives.iso / gnu / cvs-1.8 / cvs-1 / cvs-1.8.1 / doc / cvs.info-5 < prev    next >
Encoding:
GNU Info File  |  1996-05-06  |  31.2 KB  |  799 lines

  1. This is Info file cvs.info, produced by Makeinfo-1.63 from the input
  2. file ./cvs.texinfo.
  3.  
  4.    Copyright (C) 1992, 1993 Signum Support AB Copyright (C) 1993, 1994
  5. Free Software Foundation, Inc.
  6.  
  7.    Permission is granted to make and distribute verbatim copies of this
  8. manual provided the copyright notice and this permission notice are
  9. preserved on all copies.
  10.  
  11.    Permission is granted to copy and distribute modified versions of
  12. this manual under the conditions for verbatim copying, provided also
  13. that the section entitled "GNU General Public License" is included
  14. exactly as in the original, and provided that the entire resulting
  15. derived work is distributed under the terms of a permission notice
  16. identical to this one.
  17.  
  18.    Permission is granted to copy and distribute translations of this
  19. manual into another language, under the above conditions for modified
  20. versions, except that the section entitled "GNU General Public License"
  21. and this permission notice may be included in translations approved by
  22. the Free Software Foundation instead of in the original English.
  23.  
  24. 
  25. File: cvs.info,  Node: modules,  Next: Wrappers,  Up: Administrative files
  26.  
  27. The modules file
  28. ================
  29.  
  30.    The `modules' file records your definitions of names for collections
  31. of source code.  CVS will use these definitions if you use CVS to
  32. update the modules file (use normal commands like `add', `commit', etc).
  33.  
  34.    The `modules' file may contain blank lines and comments (lines
  35. beginning with `#') as well as module definitions.  Long lines can be
  36. continued on the next line by specifying a backslash (`\') as the last
  37. character on the line.
  38.  
  39.    A module definition is a single line of the `modules' file, in
  40. either of two formats.  In both cases, MNAME represents the symbolic
  41. module name, and the remainder of the line is its definition.
  42.  
  43. `MNAME -a ALIASES...'
  44.      This represents the simplest way of defining a module MNAME.  The
  45.      `-a' flags the definition as a simple alias: CVS will treat any
  46.      use of MNAME (as a command argument) as if the list of names
  47.      ALIASES had been specified instead.  ALIASES may contain either
  48.      other module names or paths.  When you use paths in aliases,
  49.      `checkout' creates all intermediate directories in the working
  50.      directory, just as if the path had been specified explicitly in
  51.      the CVS arguments.
  52.  
  53. `MNAME [ options ] DIR [ FILES... ] [ &MODULE... ]'
  54.      In the simplest case, this form of module definition reduces to
  55.      `MNAME DIR'.  This defines all the files in directory DIR as
  56.      module mname.  DIR is a relative path (from `$CVSROOT') to a
  57.      directory of source in the source repository.  In this case, on
  58.      checkout, a single directory called MNAME is created as a working
  59.      directory; no intermediate directory levels are used by default,
  60.      even if DIR was a path involving several directory levels.
  61.  
  62.      By explicitly specifying files in the module definition after DIR,
  63.      you can select particular files from directory DIR.  The sample
  64.      definition for `modules' is an example of a module defined with a
  65.      single file from a particular directory.  Here is another example:
  66.  
  67.           m4test  unsupported/gnu/m4 foreach.m4 forloop.m4
  68.  
  69.      With this definition, executing `cvs checkout m4test' will create
  70.      a single working directory `m4test' containing the two files
  71.      listed, which both come from a common directory several levels deep
  72.      in the CVS source repository.
  73.  
  74.      A module definition can refer to other modules by including
  75.      `&MODULE' in its definition.  `checkout' creates a subdirectory
  76.      for each such module, in your working directory.
  77.  
  78.     `-d NAME'
  79.           Name the working directory something other than the module
  80.           name.
  81.  
  82.     `-e PROG'
  83.           Specify a program PROG to run whenever files in a module are
  84.           exported.  PROG runs with a single argument, the module name.
  85.  
  86.     `-i PROG'
  87.           Specify a program PROG to run whenever files in a module are
  88.           committed.  PROG runs with a single argument, the full
  89.           pathname of the affected directory in a source repository.
  90.           The `commitinfo', `loginfo', and `editinfo' files provide
  91.           other ways to call a program on commit.
  92.  
  93.     `-o PROG'
  94.           Specify a program PROG to run whenever files in a module are
  95.           checked out.  PROG runs with a single argument, the module
  96.           name.
  97.  
  98.     `-s STATUS'
  99.           Assign a status to the module.  When the module file is
  100.           printed with `cvs checkout -s' the modules are sorted
  101.           according to primarily module status, and secondarily
  102.           according to the module name.  This option has no other
  103.           meaning.  You can use this option for several things besides
  104.           status: for instance, list the person that is responsible for
  105.           this module.
  106.  
  107.     `-t PROG'
  108.           Specify a program PROG to run whenever files in a module are
  109.           tagged with `rtag'.  PROG runs with two arguments: the module
  110.           name and the symbolic tag specified to `rtag'.  There is no
  111.           way to specify a program to run when `tag' is executed.
  112.  
  113.     `-u PROG'
  114.           Specify a program PROG to run whenever `cvs update' is
  115.           executed from the top-level directory of the checked-out
  116.           module.  PROG runs with a single argument, the full path to
  117.           the source repository for this module.
  118.  
  119. 
  120. File: cvs.info,  Node: Wrappers,  Next: commit files,  Prev: modules,  Up: Administrative files
  121.  
  122. The cvswrappers file
  123. ====================
  124.  
  125.    Wrappers allow you to set a hook which transforms files on their way
  126. in and out of CVS.  Most or all of the wrappers features do not work
  127. with client/server CVS.
  128.  
  129.    The file `cvswrappers' defines the script that will be run on a file
  130. when its name matches a regular expresion. There are two scripts that
  131. can be run on a file or directory. One script is executed on the
  132. file/directory before being checked into the repository (this is denoted
  133. with the `-t' flag) and the other when the file is checked out of the
  134. repository (this is denoted with the `-f' flag)
  135.  
  136.    The `cvswrappers' also has a `-m' option to specify the merge
  137. methodology that should be used when the file is updated.  `MERGE'
  138. means the usual CVS behavior: try to merge the files (this generally
  139. will not work for binary files).  `COPY' means that `cvs update' will
  140. merely copy one version over the other, and require the user using
  141. mechanisms outside CVS, to insert any necessary changes.  The `-m'
  142. wrapper option only affects behavior when merging is done on update; it
  143. does not affect how files are stored.  See *Note Binary files::, for
  144. more on binary files.
  145.  
  146.    The basic format of the file `cvswrappers' is:
  147.  
  148.      wildcard     [option value][option value]...
  149.      
  150.      where option is one of
  151.      -f           from cvs filter         value: path tofilter
  152.      -t           to cvs filter           value: path to filter
  153.      -m           update methodology      value: MERGE or COPY
  154.      
  155.      and value is a single-quote delimited value.
  156.  
  157.      *.nib    -f 'unwrap %s' -t 'wrap %s %s' -m 'COPY'
  158.      *.c      -t 'indent %s %s'
  159.  
  160. The above example of a `cvswrappers' file states that all
  161. files/directories that end with a `.nib' should be filtered with the
  162. `wrap' program before checking the file into the repository. The file
  163. should be filtered though the `unwrap' program when the file is checked
  164. out of the repository. The `cvswrappers' file also states that a `COPY'
  165. methodology should be used when updating the files in the repository
  166. (that is no merging should be performed).
  167.  
  168.    The last example line says that all files that end with a `*.c'
  169. should be filtered with `indent' before being checked into the
  170. repository. Unlike the previous example no filtering of the `*.c' file
  171. is done when it is checked out of the repository.
  172.  
  173. The `-t' filter is called with two arguments, the first is the name of
  174. the file/directory to filter and the second is the pathname to where
  175. the resulting filtered file should be placed.
  176.  
  177. The `-f' filter is called with one argument, which is the name of the
  178. file to filter from. The end result of this filter will be a file in
  179. the users directory that they can work on as they normally would.
  180.  
  181. 
  182. File: cvs.info,  Node: commit files,  Next: commitinfo,  Prev: Wrappers,  Up: Administrative files
  183.  
  184. The commit support files
  185. ========================
  186.  
  187.    The `-i' flag in the `modules' file can be used to run a certain
  188. program whenever files are committed (*note modules::.).  The files
  189. described in this section provide other, more flexible, ways to run
  190. programs whenever something is committed.
  191.  
  192.    There are three kind of programs that can be run on commit.  They
  193. are specified in files in the repository, as described below.  The
  194. following table summarizes the file names and the purpose of the
  195. corresponding programs.
  196.  
  197. `commitinfo'
  198.      The program is responsible for checking that the commit is
  199.      allowed.  If it exits with a non-zero exit status the commit will
  200.      be aborted.
  201.  
  202. `editinfo'
  203.      The specified program is used to edit the log message, and
  204.      possibly verify that it contains all required fields.  This is
  205.      most useful in combination with the `rcsinfo' file, which can hold
  206.      a log message template (*note rcsinfo::.).
  207.  
  208. `loginfo'
  209.      The specified program is called when the commit is complete.  It
  210.      receives the log message and some additional information and can
  211.      store the log message in a file, or mail it to appropriate
  212.      persons, or maybe post it to a local newsgroup, or...  Your
  213.      imagination is the limit!
  214.  
  215. * Menu:
  216.  
  217. * syntax::                      The common syntax
  218.  
  219. 
  220. File: cvs.info,  Node: syntax,  Up: commit files
  221.  
  222. The common syntax
  223. -----------------
  224.  
  225.    The four files `commitinfo', `loginfo', `rcsinfo' and `editinfo' all
  226. have a common format.  The purpose of the files are described later on.
  227. The common syntax is described here.
  228.  
  229.    Each line contains the following:
  230.    * A regular expression
  231.  
  232.    * A whitespace separator--one or more spaces and/or tabs.
  233.  
  234.    * A file name or command-line template.
  235.  
  236. Blank lines are ignored.  Lines that start with the character `#' are
  237. treated as comments.  Long lines unfortunately can *not* be broken in
  238. two parts in any way.
  239.  
  240.    The first regular expression that matches the current directory name
  241. in the repository is used.  The rest of the line is used as a file name
  242. or command-line as appropriate.
  243.  
  244. 
  245. File: cvs.info,  Node: commitinfo,  Next: editinfo,  Prev: commit files,  Up: Administrative files
  246.  
  247. Commitinfo
  248. ==========
  249.  
  250.    The `commitinfo' file defines programs to execute whenever `cvs
  251. commit' is about to execute.  These programs are used for pre-commit
  252. checking to verify that the modified, added and removed files are really
  253. ready to be committed.  This could be used, for instance, to verify
  254. that the changed files conform to to your site's standards for coding
  255. practice.
  256.  
  257.    As mentioned earlier, each line in the `commitinfo' file consists of
  258. a regular expression and a command-line template.  The template can
  259. include a program name and any number of arguments you wish to supply
  260. to it.  The full path to the current source repository is appended to
  261. the template, followed by the file names of any files involved in the
  262. commit (added, removed, and modified files).
  263.  
  264.    The first line with a regular expression matching the relative path
  265. to the module will be used.  If the command returns a non-zero exit
  266. status the commit will be aborted.
  267.  
  268.    If the repository name does not match any of the regular expressions
  269. in this file, the `DEFAULT' line is used, if it is specified.
  270.  
  271.    All occurances of the name `ALL' appearing as a regular expression
  272. are used in addition to the first matching regular expression or the
  273. name `DEFAULT'.
  274.  
  275.    Note: when CVS is accessing a remote repository, `commitinfo' will
  276. be run on the *remote* (i.e., server) side, not the client side (*note
  277. Remote repositories::.).
  278.  
  279. 
  280. File: cvs.info,  Node: editinfo,  Next: loginfo,  Prev: commitinfo,  Up: Administrative files
  281.  
  282. Editinfo
  283. ========
  284.  
  285.    If you want to make sure that all log messages look the same way,
  286. you can use the `editinfo' file to specify a program that is used to
  287. edit the log message.  This program could be a custom-made editor that
  288. always enforces a certain style of the log message, or maybe a simple
  289. shell script that calls an editor, and checks that the entered message
  290. contains the required fields.
  291.  
  292.    If no matching line is found in the `editinfo' file, the editor
  293. specified in the environment variable `$CVSEDITOR' is used instead.  If
  294. that variable is not set, then the environment variable `$EDITOR' is
  295. used instead.  If that variable is not set a precompiled default,
  296. normally `vi', will be used.
  297.  
  298.    The `editinfo' file is often most useful together with the `rcsinfo'
  299. file, which can be used to specify a log message template.
  300.  
  301.    Each line in the `editinfo' file consists of a regular expression
  302. and a command-line template.  The template must include a program name,
  303. and can include any number of arguments.  The full path to the current
  304. log message template file is appended to the template.
  305.  
  306.    One thing that should be noted is that the `ALL' keyword is not
  307. supported.  If more than one matching line is found, the first one is
  308. used.  This can be useful for specifying a default edit script in a
  309. module, and then overriding it in a subdirectory.
  310.  
  311.    If the repository name does not match any of the regular expressions
  312. in this file, the `DEFAULT' line is used, if it is specified.
  313.  
  314.    If the edit script exits with a non-zero exit status, the commit is
  315. aborted.
  316.  
  317.    Note: when CVS is accessing a remote repository, `editinfo' will be
  318. run on the *remote* (i.e., server) side, not the client side (*note
  319. Remote repositories::.).
  320.  
  321. * Menu:
  322.  
  323. * editinfo example::            Editinfo example
  324.  
  325. 
  326. File: cvs.info,  Node: editinfo example,  Up: editinfo
  327.  
  328. Editinfo example
  329. ----------------
  330.  
  331.    The following is a little silly example of a `editinfo' file,
  332. together with the corresponding `rcsinfo' file, the log message
  333. template and an editor script.  We begin with the log message template.
  334. We want to always record a bug-id number on the first line of the log
  335. message.  The rest of log message is free text.  The following template
  336. is found in the file `/usr/cvssupport/tc.template'.
  337.  
  338.      BugId:
  339.  
  340.    The script `/usr/cvssupport/bugid.edit' is used to edit the log
  341. message.
  342.  
  343.      #!/bin/sh
  344.      #
  345.      #       bugid.edit filename
  346.      #
  347.      #  Call $EDITOR on FILENAME, and verify that the
  348.      #  resulting file contains a valid bugid on the first
  349.      #  line.
  350.      if [ "x$EDITOR" = "x" ]; then EDITOR=vi; fi
  351.      if [ "x$CVSEDITOR" = "x" ]; then CVSEDITOR=$EDITOR; fi
  352.      $CVSEDITOR $1
  353.      until head -1|grep '^BugId:[ ]*[0-9][0-9]*$' < $1
  354.      do  echo -n  "No BugId found.  Edit again? ([y]/n)"
  355.          read ans
  356.          case ${ans} in
  357.              n*) exit 1;;
  358.          esac
  359.          $CVSEDITOR $1
  360.      done
  361.  
  362.    The `editinfo' file contains this line:
  363.  
  364.      ^tc     /usr/cvssupport/bugid.edit
  365.  
  366.    The `rcsinfo' file contains this line:
  367.  
  368.      ^tc     /usr/cvssupport/tc.template
  369.  
  370. 
  371. File: cvs.info,  Node: loginfo,  Next: rcsinfo,  Prev: editinfo,  Up: Administrative files
  372.  
  373. Loginfo
  374. =======
  375.  
  376.    The `loginfo' file is used to control where `cvs commit' log
  377. information is sent.  The first entry on a line is a regular expression
  378. which is tested against the directory that the change is being made to,
  379. relative to the `$CVSROOT'.  If a match is found, then the remainder of
  380. the line is a filter program that should expect log information on its
  381. standard input.
  382.  
  383.    The filter program may use one and only one % modifier (a la
  384. printf).  If `%s' is specified in the filter program, a brief title is
  385. included (enclosed in single quotes) showing the modified file names.
  386.  
  387.    If the repository name does not match any of the regular expressions
  388. in this file, the `DEFAULT' line is used, if it is specified.
  389.  
  390.    All occurances of the name `ALL' appearing as a regular expression
  391. are used in addition to the first matching regular expression or
  392. `DEFAULT'.
  393.  
  394.    The first matching regular expression is used.
  395.  
  396.    *Note commit files::, for a description of the syntax of the
  397. `loginfo' file.
  398.  
  399.    Note: when CVS is accessing a remote repository, `loginfo' will be
  400. run on the *remote* (i.e., server) side, not the client side (*note
  401. Remote repositories::.).
  402.  
  403. * Menu:
  404.  
  405. * loginfo example::             Loginfo example
  406.  
  407. 
  408. File: cvs.info,  Node: loginfo example,  Up: loginfo
  409.  
  410. Loginfo example
  411. ---------------
  412.  
  413.    The following `loginfo' file, together with the tiny shell-script
  414. below, appends all log messages to the file
  415. `$CVSROOT/CVSROOT/commitlog', and any commits to the administrative
  416. files (inside the `CVSROOT' directory) are also logged in
  417. `/usr/adm/cvsroot-log'.
  418.  
  419.      ALL             /usr/local/bin/cvs-log $CVSROOT/CVSROOT/commitlog
  420.      ^CVSROOT        /usr/local/bin/cvs-log /usr/adm/cvsroot-log
  421.  
  422.    The shell-script `/usr/local/bin/cvs-log' looks like this:
  423.  
  424.      #!/bin/sh
  425.      (echo "-----------------------------------------------------------------";
  426.       echo -n $USER"  ";
  427.       date;
  428.       echo;
  429.       sed '1s+'${CVSROOT}'++') >> $1
  430.  
  431. 
  432. File: cvs.info,  Node: rcsinfo,  Next: cvsignore,  Prev: loginfo,  Up: Administrative files
  433.  
  434. Rcsinfo
  435. =======
  436.  
  437.    The `rcsinfo' file can be used to specify a form to edit when
  438. filling out the commit log.  The `rcsinfo' file has a syntax similar to
  439. the `editinfo', `commitinfo' and `loginfo' files.  *Note syntax::.
  440. Unlike the other files the second part is *not* a command-line
  441. template.  Instead, the part after the regular expression should be a
  442. full pathname to a file containing the log message template.
  443.  
  444.    If the repository name does not match any of the regular expressions
  445. in this file, the `DEFAULT' line is used, if it is specified.
  446.  
  447.    All occurances of the name `ALL' appearing as a regular expression
  448. are used in addition to the first matching regular expression or
  449. `DEFAULT'.
  450.  
  451.    The log message template will be used as a default log message.  If
  452. you specify a log message with `cvs commit -m MESSAGE' or `cvs commit -f
  453. FILE' that log message will override the template.
  454.  
  455.    *Note editinfo example::, for an example `rcsinfo' file.
  456.  
  457.    When CVS is accessing a remote repository, the contents of `rcsinfo'
  458. at the time a directory is first checked out will specify a template
  459. which does not then change.  If you edit `rcsinfo' or its templates,
  460. you may need to check out a new working directory.
  461.  
  462. 
  463. File: cvs.info,  Node: cvsignore,  Next: history file,  Prev: rcsinfo,  Up: Administrative files
  464.  
  465. Ignoring files via cvsignore
  466. ============================
  467.  
  468.    There are certain file names that frequently occur inside your
  469. working copy, but that you don't want to put under CVS control.
  470. Examples are all the object files that you get while you compile your
  471. sources.  Normally, when you run `cvs update', it prints a line for
  472. each file it encounters that it doesn't know about (*note update
  473. output::.).
  474.  
  475.    CVS has a list of files (or sh(1) file name patterns) that it should
  476. ignore while running `update', `import' and `release'.  This list is
  477. constructed in the following way.
  478.  
  479.    * The list is initialized to include certain file name patterns:
  480.      names associated with CVS administration, or with other common
  481.      source control systems; common names for patch files, object files,
  482.      archive files, and editor backup files; and other names that are
  483.      usually artifacts of assorted utilities.  Currently, the default
  484.      list of ignored file name patterns is:
  485.  
  486.               RCS     SCCS    CVS     CVS.adm
  487.               RCSLOG  cvslog.*
  488.               tags    TAGS
  489.               .make.state     .nse_depinfo
  490.               *~      #*      .#*     ,*      _$*     *$
  491.               *.old   *.bak   *.BAK   *.orig  *.rej   .del-*
  492.               *.a     *.olb   *.o     *.obj   *.so    *.exe
  493.               *.Z     *.elc   *.ln
  494.               core
  495.  
  496.    * The per-repository list in `$CVSROOT/CVSROOT/cvsignore' is
  497.      appended to the list, if that file exists.
  498.  
  499.    * The per-user list in `.cvsignore' in your home directory is
  500.      appended to the list, if it exists.
  501.  
  502.    * Any entries in the environment variable `$CVSIGNORE' is appended
  503.      to the list.
  504.  
  505.    * Any `-I' options given to CVS is appended.
  506.  
  507.    * As CVS traverses through your directories, the contents of any
  508.      `.cvsignore' will be appended to the list.  The patterns found in
  509.      `.cvsignore' are only valid for the directory that contains them,
  510.      not for any sub-directories.
  511.  
  512.    In any of the 5 places listed above, a single exclamation mark (`!')
  513. clears the ignore list.  This can be used if you want to store any file
  514. which normally is ignored by CVS.
  515.  
  516. 
  517. File: cvs.info,  Node: history file,  Next: Setting up,  Prev: cvsignore,  Up: Administrative files
  518.  
  519. The history file
  520. ================
  521.  
  522.    The file `$CVSROOT/CVSROOT/history' is used to log information for
  523. the `history' command (*note history::.).  This file must be created to
  524. turn on logging.  This is done automatically if the `cvs init' command
  525. is used to set up the repository (*note Setting up::.).
  526.  
  527.    The file format of the `history' file is documented only in comments
  528. in the CVS source code, but generally programs should use the `cvs
  529. history' command to access it anyway, in case the format changes with
  530. future releases of CVS.
  531.  
  532. 
  533. File: cvs.info,  Node: Setting up,  Next: Variables,  Prev: history file,  Up: Administrative files
  534.  
  535. Setting up the repository
  536. =========================
  537.  
  538.    To set up a CVS repository, choose a directory with ample disk space
  539. available for the revision history of the source files.  It should be
  540. accessable (directly or via a networked file system) from all machines
  541. which want to use CVS in server or local mode; the client machines need
  542. not have any access to it other than via the CVS protocol.
  543.  
  544.    To create a repository, run the `cvs init' command.  It will set up
  545. an empty repository in the CVS root specified in the usual way (*note
  546. Repository::.).  For example,
  547.  
  548.      cvs -d /usr/local/cvsroot init
  549.  
  550.    `cvs init' is careful to never overwrite any existing files in the
  551. repository, so no harm is done if you run `cvs init' on an already
  552. set-up repository.
  553.  
  554.    `cvs init' will enable history logging; if you don't want that,
  555. remove the history file after running `cvs init'.  *Note history file::.
  556.  
  557. 
  558. File: cvs.info,  Node: Variables,  Prev: Setting up,  Up: Administrative files
  559.  
  560. Expansions in administrative files
  561. ==================================
  562.  
  563.    Sometimes in writing an administrative file, you might want the file
  564. to be able to know various things based on environment CVS is running
  565. in.  There are several mechanisms to do that.
  566.  
  567.    To find the home directory of the user running CVS (from the `HOME'
  568. environment variable), use `~' followed by `/' or the end of the line.
  569. Likewise for the home directory of USER, use `~USER'.  These variables
  570. are expanded on the server machine, and don't get any resonable
  571. expansion if pserver (*note Password authenticated::.) is in used;
  572. therefore user variables (see below) may be a better choice to
  573. customize behavior based on the user running CVS.
  574.  
  575.    One may want to know about various pieces of information internal to
  576. CVS.  A CVS internal variable has the syntax `${VARIABLE}', where
  577. VARIABLE starts with a letter and consists of alphanumberic characters
  578. and `_'.  If the character following VARIABLE is a non-alphanumeric
  579. character other than `_', the `{' and `}' can be omitted.  The CVS
  580. internal variables are:
  581.  
  582. `CVSROOT'
  583.      This is the value of the CVS root in use.  *Note Repository::, for
  584.      a description of the various ways to specify this.
  585.  
  586. `RCSBIN'
  587.      This is the value CVS is using for where to find RCS binaries.
  588.      *Note Global options::, for a description of how to specify this.
  589.  
  590. `CVSEDITOR'
  591. `VISUAL'
  592. `EDITOR'
  593.      These all expand to the same value, which is the editor that CVS
  594.      is using.  *Note Global options::, for how to specify this.
  595.  
  596. `USER'
  597.      Username of the user running CVS (on the CVS server machine).
  598.  
  599.    If you want to pass a value to the administrative files which the
  600. user that is running CVS can specify, use a user variable.  To expand a
  601. user variable, the administrative file contains `${=VARIABLE}'.  To set
  602. a user variable, specify the global option `-s' to CVS, with argument
  603. `VARIABLE=VALUE'.  It may be particularly useful to specify this option
  604. via `.cvsrc' (*note ~/.cvsrc::.).
  605.  
  606.    For example, if you want the administrative file to refer to a test
  607. directory you might create a user variable `TESTDIR'.  Then if CVS is
  608. invoked as `cvs -s TESTDIR=/work/local/tests', and the administrative
  609. file contains `sh ${=TESTDIR}/runtests', then that string is expanded
  610. to `sh /work/local/tests/runtests'.
  611.  
  612.    All other strings containing `$' are reserved; there is no way to
  613. quote a `$' character so that `$' represents itself.
  614.  
  615. 
  616. File: cvs.info,  Node: Environment variables,  Next: Troubleshooting,  Prev: Administrative files,  Up: Top
  617.  
  618. All environment variables which affect CVS
  619. ******************************************
  620.  
  621.    This is a complete list of all environment variables that affect CVS.
  622.  
  623. `$CVSIGNORE'
  624.      A whitespace-separated list of file name patterns that CVS should
  625.      ignore. *Note cvsignore::.
  626.  
  627. `$CVSWRAPPERS'
  628.      A whitespace-separated list of file name patterns that CVS should
  629.      treat as wrappers. *Note Wrappers::.
  630.  
  631. `$CVSREAD'
  632.      If this is set, `checkout' and `update' will try hard to make the
  633.      files in your working directory read-only.  When this is not set,
  634.      the default behavior is to permit modification of your working
  635.      files.
  636.  
  637. `$CVSROOT'
  638.      Should contain the full pathname to the root of the CVS source
  639.      repository (where the RCS history files are kept).  This
  640.      information must be available to CVS for most commands to execute;
  641.      if `$CVSROOT' is not set, or if you wish to override it for one
  642.      invocation, you can supply it on the command line: `cvs -d cvsroot
  643.      cvs_command...' Once you have checked out a working directory, CVS
  644.      stores the appropriate root (in the file `CVS/Root'), so normally
  645.      you only need to worry about this when initially checking out a
  646.      working directory.
  647.  
  648. `$EDITOR'
  649. `$CVSEDITOR'
  650.      Specifies the program to use for recording log messages during
  651.      commit.  If not set, the default is `/usr/ucb/vi'.  `$CVSEDITOR'
  652.      overrides `$EDITOR'.  `$CVSEDITOR' does not exist in CVS 1.3, but
  653.      the next release will probably include it.
  654.  
  655. `$PATH'
  656.      If `$RCSBIN' is not set, and no path is compiled into CVS, it will
  657.      use `$PATH' to try to find all programs it uses.
  658.  
  659. `$RCSBIN'
  660.      Specifies the full pathname of the location of RCS programs, such
  661.      as co(1) and ci(1).  If not set, a compiled-in value is used, or
  662.      your `$PATH' is searched.
  663.  
  664. `$HOME'
  665. `$HOMEPATH'
  666.      Used to locate the directory where the `.cvsrc' file is searched
  667.      (`$HOMEPATH' is used for Windows-NT).  *note ~/.cvsrc::.
  668.  
  669. `$CVS_RSH'
  670.      Used in client-server mode when accessing a remote repository
  671.      using RSH.  The default value is `rsh'.  You can set it to use
  672.      another program for accssing the remote server (e.g. for HP-UX 9,
  673.      you should set it to `remsh' because `rsh' invokes the restricted
  674.      shell).  *note Connecting via rsh::.
  675.  
  676. `$CVS_SERVER'
  677.      Used in client-server mode when accessing a remote repository
  678.      using RSH.  It specifies the name of the program to start on the
  679.      server side when accessing a remote repository using RSH.  The
  680.      default value is `cvs'.  *note Connecting via rsh::.
  681.  
  682. `$CVS_PASSFILE'
  683.      Used in client-server mode when accessing the `cvs login server'.
  684.      Default value is `$HOME/.cvspass'.  *note Password authentication
  685.      client::.
  686.  
  687. `$CVS_PASSWORD'
  688.      Used in client-server mode when accessing the `cvs login server'.
  689.      *note Password authentication client::.
  690.  
  691. `$CVS_CLIENT_PORT'
  692.      Used in client-server mode when accessing the server via Kerberos.
  693.      *note Kerberos authenticated::.
  694.  
  695. `$CVS_RCMD_PORT'
  696.      Used in client-server mode.  If set, specifies the port number to
  697.      be used when accessing the RCMD demon on the server side.
  698.      (Currently not used for Unix clients).
  699.  
  700. `$CVS_CLIENT_LOG'
  701.      Used for debugging only in client-server mode.  If set, everything
  702.      send to the server is logged into ``$CVS_CLIENT_LOG'.in' and
  703.      everything send from the server is logged into
  704.      ``$CVS_CLIENT_LOG'.out'.
  705.  
  706. `$CVS_SERVER_SLEEP'
  707.      Used only for debugging the server side in client-server mode.  If
  708.      set, delays the start of the server child process the the
  709.      specified amount of seconds so that you can attach to it with a
  710.      debugger.
  711.  
  712. `$CVS_IGNORE_REMOTE_ROOT'
  713.      (What is the purpose of this variable?)
  714.  
  715. `$COMSPEC'
  716.      Used under OS/2 only.  It specifies the name of the command
  717.      interpreter and defaults to CMD.EXE.
  718.  
  719.    CVS is a front-end to RCS.  The following environment variables
  720. affect RCS.  Note that if you are using the client/server CVS, these
  721. variables need to be set on the server side (which may or not may be
  722. possible depending on how you are connecting).  There is probably not
  723. any need to set any of them, however.
  724.  
  725. `$LOGNAME'
  726. `$USER'
  727.      If set, they affect who RCS thinks you are.  If you have trouble
  728.      checking in files it might be because your login name differs from
  729.      the setting of e.g.  `$LOGNAME'.
  730.  
  731. `$RCSINIT'
  732.      Options prepended to the argument list, separated by spaces.  A
  733.      backslash escapes spaces within an option.  The `$RCSINIT' options
  734.      are prepended to the argument lists of most RCS commands.
  735.  
  736. `$TMPDIR'
  737. `$TMP'
  738. `$TEMP'
  739.      Name of the temporary directory.  The environment variables are
  740.      inspected in the order they appear above and the first value found
  741.      is taken; if none of them are set, a host-dependent default is
  742.      used, typically `/tmp'.
  743.  
  744. 
  745. File: cvs.info,  Node: Troubleshooting,  Next: Copying,  Prev: Environment variables,  Up: Top
  746.  
  747. Troubleshooting
  748. ***************
  749.  
  750. * Menu:
  751.  
  752. * Magic branch numbers::        Magic branch numbers
  753.  
  754. 
  755. File: cvs.info,  Node: Magic branch numbers,  Up: Troubleshooting
  756.  
  757. Magic branch numbers
  758. ====================
  759.  
  760.    Externally, branch numbers consist of an odd number of dot-separated
  761. decimal integers.  *Note Revision numbers::.  That is not the whole
  762. truth, however.  For efficiency reasons CVS sometimes inserts an extra 0
  763. in the second rightmost position (1.2.3 becomes 1.2.0.3, 8.9.10.11.12
  764. becomes 8.9.10.11.0.12 and so on).
  765.  
  766.    CVS does a pretty good job at hiding these so called magic branches,
  767. but in at least four places the hiding is incomplete.
  768.  
  769.    * The magic branch can appear in the output from `cvs status' in
  770.      vanilla CVS 1.3.  This is fixed in CVS 1.3-s2.
  771.  
  772.    * The magic branch number appears in the output from `cvs log'.
  773.      This is much harder to fix, since `cvs log' runs `rlog' (which is
  774.      part of the RCS distribution), and modifying `rlog' to know about
  775.      magic branches would probably break someone's habits (if they use
  776.      branch 0 for their own purposes).
  777.  
  778.    * You cannot specify a symbolic branch name to `cvs log'.
  779.  
  780.    * You cannot specify a symbolic branch name to `cvs admin'.
  781.  
  782.    You can use the `admin' command to reassign a symbolic name to a
  783. branch the way RCS expects it to be.  If `R4patches' is assigned to the
  784. branch 1.4.2 (magic branch number 1.4.0.2) in file `numbers.c' you can
  785. do this:
  786.  
  787.      $ cvs admin -NR4patches:1.4.2 numbers.c
  788.  
  789.    It only works if at least one revision is already committed on the
  790. branch.  Be very careful so that you do not assign the tag to the wrong
  791. number.  (There is no way to see how the tag was assigned yesterday).
  792.  
  793. 
  794. File: cvs.info,  Node: Copying,  Next: Index,  Prev: Troubleshooting,  Up: Top
  795.  
  796. GNU GENERAL PUBLIC LICENSE
  797. **************************
  798.  
  799.